const express = require('express');
const ejs = require('ejs');
const pageRouter = require('./routes/pageRouter')
const apiRouter = require('./routes/apiRouter');
const app = express();
app.listen(80,()=>{
    console.log("80端口启动成功");
})

app.set('views',__dirname+'/html');
app.engine('html',ejs.renderFile);

app.use(express.static(__dirname+'/public'))
app.use(express.urlencoded({extended:true}));

app.use(pageRouter);
app.use(apiRouter);

